package com.ims.core.doc.service.impl;

import java.util.List;
import com.ims.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ims.core.doc.mapper.TInNon1012Mapper;
import com.ims.core.doc.domain.TInNon1012;
import com.ims.core.doc.service.ITInNon1012Service;

/**
 * 医疗电子票据（门诊）1012Service业务层处理
 *
 * @author IMS
 * @date 2024-11-25
 */
@Service
public class TInNon1012ServiceImpl implements ITInNon1012Service
{
    @Autowired
    private TInNon1012Mapper tInNon1012Mapper;

    /**
     * 查询医疗电子票据（门诊）1012
     *
     * @param id 医疗电子票据（门诊）1012主键
     * @return 医疗电子票据（门诊）1012
     */
    @Override
    public TInNon1012 selectTInNon1012ById(Long id)
    {
        return tInNon1012Mapper.selectTInNon1012ById(id);
    }

    /**
     * 查询医疗电子票据（门诊）1012列表
     *
     * @param tInNon1012 医疗电子票据（门诊）1012
     * @return 医疗电子票据（门诊）1012
     */
    @Override
    public List<TInNon1012> selectTInNon1012List(TInNon1012 tInNon1012)
    {
        return tInNon1012Mapper.selectTInNon1012List(tInNon1012);
    }

    /**
     * 新增医疗电子票据（门诊）1012
     *
     * @param tInNon1012 医疗电子票据（门诊）1012
     * @return 结果
     */
    @Override
    public int insertTInNon1012(TInNon1012 tInNon1012)
    {
        tInNon1012.setCreateTime(DateUtils.getNowDate());
        return tInNon1012Mapper.insertTInNon1012(tInNon1012);
    }

    /**
     * 修改医疗电子票据（门诊）1012
     *
     * @param tInNon1012 医疗电子票据（门诊）1012
     * @return 结果
     */
    @Override
    public int updateTInNon1012(TInNon1012 tInNon1012)
    {
        tInNon1012.setUpdateTime(DateUtils.getNowDate());
        return tInNon1012Mapper.updateTInNon1012(tInNon1012);
    }

    /**
     * 批量删除医疗电子票据（门诊）1012
     *
     * @param ids 需要删除的医疗电子票据（门诊）1012主键
     * @return 结果
     */
    @Override
    public int deleteTInNon1012ByIds(Long[] ids)
    {
        return tInNon1012Mapper.deleteTInNon1012ByIds(ids);
    }

    /**
     * 删除医疗电子票据（门诊）1012信息
     *
     * @param id 医疗电子票据（门诊）1012主键
     * @return 结果
     */
    @Override
    public int deleteTInNon1012ById(Long id)
    {
        return tInNon1012Mapper.deleteTInNon1012ById(id);
    }
}
